from django.urls import path, re_path, include
from .md_user import Register, SendEmail, SendPhone, UserLogin, TeipartiteBack, tripartiteUrl, UserView, UserPhoto
from .md_work import WorkApi, WorkTypeApi, TaskApi, GetOneWork, MyWorkApi, UploadFile,Deleteimg, GetRanking
from .md_message import ShowMessage,websocketlink, messagewebsocket, SendMessage, OnlineUser,MsgImg,ShowMsgRecord

urlpatterns = [
    # 用户路由
    path('register/', Register.as_view()),
    path('sendemail/', SendEmail.as_view()),
    path('sendphone/', SendPhone.as_view()),
    path('userlogin/', UserLogin.as_view()),
    path('teipartite_back/', TeipartiteBack.as_view()),
    path('userview/', UserView.as_view()),
    # path('gitee_back/', GiteeBack.as_view()),
    path('tripartiteurl/', tripartiteUrl),
    path('userphoto/', UserPhoto.as_view()),  ## 接口文档

    # 工单路由
    path('taskapi/', TaskApi.as_view()),
    path('worktypeapi/', WorkTypeApi.as_view()),
    path('workapi/', WorkApi.as_view()),
    path('getonework/', GetOneWork.as_view()),
    path('myworkapi/', MyWorkApi.as_view()),
    path('uploadfile/', UploadFile.as_view()),
    path('deleteimg/', Deleteimg.as_view()),
    path('websocketlink/', websocketlink),
    path('getranking/', GetRanking.as_view()),

    # 消息路由
    path('showmessage/', ShowMessage.as_view()),
    path('messagewebsocket/', messagewebsocket),
    path('sendmessage/', SendMessage.as_view()),
    path('onlineuser/', OnlineUser.as_view()),
    path('msgimg/', MsgImg.as_view()),
    path('showmsgrecord/', ShowMsgRecord.as_view()),

]